<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<script type="text/javascript" src="../js/angular.min.js"></script>
	</head>
	<body ng-app="myapp" ng-controller="myctrl">
		
		<table width="90%" border="1">
			<tr>
				<td>序号</td>
				<td>商品编号</td>
				<td>商品名称</td>
				<td>商品价格</td>
			</tr>
			<tr ng-repeat="product in products">
				<td>{{$indext+1}}</td>
				<td>{{product.id}}</td>
				<td>{{product.name}}</td>
				<td>{{product.price}}</td>
			</tr>
			<script type="text/javascript">
				var myapp=angular.module("myapp",[]);
				myapp.controller("myctrl",["$scope",function($scope){
					$scope.products=[
					
					{
						id:1001,
						name:'数码相机',
						price:1000
					},
					{
						id:1002,
						name:'烟酒茶汤',
						price:100
					}
					];
				}])
			</script>
		</table>
	</body>
</html>
